Troubleshooting and Configuring the Windows NT/95 Registry
-14-
Windows 95 and Plug
and Play
Windows 95 also uses a HAL (Hardware Abstraction Layer), but it is quite different
from the one in Windows NT. Instead of being the absolute solution to hardware access
as in NT, in Windows 95, the HAL is a recommended solution. Every time Windows 95
loads, a new HAL is created, based on the actual hardware present. The hooks for
applications and drivers are still there, but they are an optional item. If software
vendors want to write information directly to the hardware device, they can do so.
That helps software to have more of an operating system-independent nature, although
all drivers for supported hardware would have to be included in the application.
Games are a common example of writing directly to the hardware. The number of
supported devices is very small, and, in many cases, there is a performance benefit
derived from direct access. Fax modems and tape drives are also examples of using
built-in drivers and bypassing the HAL. Most applications prefer to use the HAL and
drivers that support it. One exception, in the past, was WordPerfect software. You
had the choice of using Windows drivers for printing, or using WordPerfect printer
drivers. Those included with WordPerfect were extremely fast, and had many benefits
over Windows printer drivers, but the maintenance of them was too time-consuming
and difficult.
Another huge difference in the HAL between Windows 95 and Windows NT is its construction.
The Windows 95 HAL is assembled at startup with Plug and Play. For optimum performance
and reliability, there are several items necessary. If any of the following items
is missing, there are limitations on how well Plug and Play can work:
- Plug and Play BIOS on the system board
- Plug and Play BIOS on the interface cards
- Plug and Play functions in Windows 95
The goal of all three is to create easier-to-use configuration procedures and
to eliminate conflicts in the settings of devices. The conflict resolution is done
by changing one or more settings on devices or in the Windows 95 Registry.
Plug and Play BIOS on the System
Board
Normally, the BIOS on a system board is configurable only through an on-board
setup program. By standardizing the procedure for setting the BIOS data and allowing
an outside program to make the settings, Phoenix Technologies made Plug and Play
a reality for the system BIOS. Now, Windows 95 can change the BIOS settings for any
BIOS-supported device as necessary to remove conflicts.
Windows 95 will continue to make BIOS calls for some devices, even though most
BIOS-supported devices are driven directly through 32-bit drivers. By actually changing
the settings in the BIOS, the system does not need to go through a conflict resolution
every time 95 loads.
If there is no Plug and Play BIOS on the system board, Windows 95 will translate
the settings that are present and use its own settings. Then, every time that device
is activated, there will be a translation. That slows access to the devices and hurts
overall performance.
Plug and Play BIOS on Interface
Cards
A Plug and Play BIOS on an interface card allows the card settings to be made
with software. That software may be supplied with the card, or the card may be configurable
with Windows 95 Plug and Play functions. By allowing the card to be set with software
after the physical installation, it can streamline troubleshooting and maintenance.
If the card was incorrectly configured with hardware settings, it would be necessary
to open the case, remove the cards, and change the settings. If the card is configured
with software, the settings are changed, and the system will normally need to be
restarted to activate the new settings.
Plug and Play Functions in
Windows 95
The Plug and Play function inside Windows 95 reports its findings to the Registry,
and the data is held in HKEY_DYN_DATA. It is the only handle key that is
not stored on the hard disk. All of its functions start with Windows 95, and are
discarded at shutdown. In between, part of the data is written into HKEY_LOCAL_MACHINE\Config.
Whenever the system needs information about the settings of a device, it will look
to HKEY_DYN_DATA for it. Each of the subkeys under Config Manager, shown
in Figure 14.1, holds information about a specific device, including the settings
and configuration.
Figure
14.1. Device configuration
and control in HKEY_DYN_DATA.
The highlighted key is the one that controls the COM1 serial port, as shown in the
HKEY_LOCAL_MACHINE\Enum\BIOS\PNP0501\00 key. The key from HKEY_LOCAL_MACHINE
tells the system where to find the actual configuration data in HKEY_DYN_DATA.
If the system loses information about any of the hardware, and things don't seem
to be working correctly, the first thing to do is to restart Windows 95. At restart,
Windows 95 will examine the device and set the device settings dynamically.
Putting It All Together
If your system has all three Plug and Play components, it is extremely easy to
set up and configure. Figure 14.2 illustrates a system where IRQ settings need to
be matched for the device to work.
Figure
14.2. System settings,
card settings, and BIOS settings must agree.
If all the devices are Plug and Play, during setup, the settings would be changed
by Windows 95, and they would all be set correctly. Figure 14.3 shows the result
of changed settings, where the settings have all changed to match.
Figure
14.3. System settings,
card settings, and BIOS settings in agreement.
If one or more of the devices is not compliant with Plug and Play, Windows 95 will
set what it can, and then translate to that which it cannot change. Figure 14.4 shows
the translation for the card settings, because the card was not Plug and Play.
Figure
14.4. Card settings
cannot be changed, so the data is translated.
Obviously, the system will be slowed because of the translation. The card will still
work at IRQ 4, but it will not work as fast. There are also some cards that will
not work at all this way. The best configuration is to have all Plug and Play devices,
if possible.
Making the Settings in Windows
95
Start Windows 95 and go to the System applet in the Control Panel. At the Device
Manager tab, select each item to look for any item where there is a red X, which
indicates that the device has been found, but it is not working at all. If you see
a yellow circle with an exclamation point, as shown in Figure 14.5, it means that
the device has not been configured correctly.
Figure
14.5. The 33.6Modem
is configured incorrectly.
Double-click on the device, and the system may tell you the problem, and how to correct
it. Figure 14.6 gives you the instructions to solve the problem.
Figure
14.6. 33.6Modem
Properties screen gives instructions for eliminating conflict.
If the instructions are not sufficient to allow you to troubleshoot and configure
the device correctly, you will need to try to isolate the problem manually. First,
you should ensure that the physical installation of the device was done correctly.
Next, you should check the settings on the device and see if they are set to available
settings in the system. Finally, you need to confirm that the driver that was installed
is the proper one and is set up correctly.
Once the configuration is established, the data is written into HKEY_LOCAL_MACHINE
and then used at subsequent startups. The system will find out what the device is
set to, read the Registry to see if it is supposed to be set to another setting,
and then the final setting is written into HKEY_DYN_DATA. Every time the
device is used, the information comes out of HKEY_DYN_DATA.
Summary
The dynamic nature of Plug and Play allows easy configuration of most devices
in Windows 95. Nearly all new devices can be configured dynamically, and they work
extremely well. Most devices, even those that do not support Plug and Play, can still
be dynamically configured, but the performance suffers. In some situations, translation
will not work, and the setting will have to be made manually.
All of the settings are stored in the Registry for Windows 95 to use to start
and operate the devices.
|